<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:th="http://www.thymeleaf.org">
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<title>SpringBoot Actuator Demo</title>
<meta
	content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
	name="viewport" />
<link rel="stylesheet"
	th:href="@{/webjars/bootstrap/3.3.7/css/bootstrap.min.css}" />
<link rel="stylesheet" th:href="@{/css/styles.css}" />

</head>

<body>
	<nav class="navbar navbar-inverse navbar-fixed-top">
		<div class="container">
			<div class="navbar-header">
				<button type="button" class="navbar-toggle collapsed"
					data-toggle="collapse" data-target="#navbar" aria-expanded="false"
					aria-controls="navbar">
					<span class="sr-only">Toggle navigation</span> <span
						class="icon-bar"></span> <span class="icon-bar"></span> <span
						class="icon-bar"></span>
				</button>
				<a class="navbar-brand" th:href="@{/}" th:text=#{app.title}>SpringBoot
					Actuator</a>
			</div>
			<div id="navbar" class="collapse navbar-collapse">
          <ul class="nav navbar-nav">
            <li><a th:href="@{/application}" target="_blank">Actuator</a></li>
          </ul>
        </div>
		</div>
	</nav>

	<div class="container">
		<div class="row">
			<div class="panel panel-default">
				<div class="panel-heading">Login Form</div>
				<div class="panel-body">
					<form class="form-horizontal" th:action="@{/login}" method="post">
						<p style="color: red" th:text="${status}">Status</p>
						<div class="form-group">
							<label>Email</label> <input type="text" name="email" />
						</div>

						<div class="form-group">
							<label>Password</label> <input type="password" name="password"
								placeholder="Enter password" />
						</div>

						<div class="form-group">
							<button type="submit" class="btn btn-primary">Login</button>
						</div>
					</form>

				</div>
			</div>
		</div>

		<div class="row">
			<div class="panel panel-default">
				<div class="panel-heading">Search GitHub Users</div>
				<div class="panel-body">
					<form class="form-horizontal" method="get" action="userInfo">
						<p>
							<input type="text" name="username"></input> <input type="submit"
								value="Search"></input>
						</p>
					</form>
					<div th:if="${githubUser == null}">
						<p>No user found</p>
					</div>
					<div th:if="${githubUser != null}">
						<p>
							Name: <span th:text="${githubUser.name}">name</span>
						</p>
						<p>
							Location: <span th:text="${githubUser.location}">location</span>
						</p>
						<p>
							Email: <span th:text="${githubUser.email}">email</span>
						</p>
						<p>
							Blog: <span th:text="${githubUser.blog}">blog</span>
						</p>
						<p>
							GitHub URL: <span th:text="${githubUser.url}">url</span>
						</p>

					</div>
				</div>
			</div>
		</div>

	</div>

	<script th:src="@{'/webjars/jquery/1.11.1/jquery.min.js'}"></script>
	<script th:src="@{'/webjars/bootstrap/3.3.7/js/bootstrap.min.js'}"></script>

</body>
</html>